1
Introduction to Core Prompting Functional Areas
AI010 Lesson 2
00:00

The Five Pillars of Prompting

Beyond simple chat interfaces, Large Language Models (LLMs) serve as sophisticated engines for structured data processing. This lesson introduces the five functional "primitives" that allow developers to integrate AI into professional workflows.

The Functional Roadmap

  • Summarizing: Condensing voluminous text (like product reviews) into concise briefs while maintaining key information.
  • Inferring: Performing automated analysis, such as sentiment detection, emotion identification, or extracting specific data points like brand names into JSON.
  • Transforming: Converting text from one form to another—this includes language translation, tone adjustment (e.g., formal to casual), and data format conversion (e.g., JSON to HTML).
  • Expanding: Taking short signals or bullet points and generating long-form content, such as personalized customer service emails.
  • Chatbots: Utilizing conversation history and defined roles (System, User, Assistant) to build interactive, context-aware assistants.
The Stateless Nature of LLMs
Crucial Concept: Unlike humans, LLMs are "stateless." They do not remember previous interactions unless you manually pass the entire conversation history back to them in each API call. This accumulated history is known as Context.
main.py
TERMINAL bash — 80x24
> Ready. Click "Run" to execute.
>
Question 1
A developer needs to extract the "Price" and "Discount Code" from 1,000 emails and save them to a database. Which approach and temperature setting are most appropriate?
A) Summarizing with Temperature = 0.7
B) Expanding with Temperature = 0
C) Inferring (Extracting) with Temperature = 0
D) Transforming with Temperature = 1.0
Challenge: Tone Transformer
Apply the Transforming and Chatbot role concepts.
You are building a "Tone Transformer" for a corporate helpdesk. You need to convert a frustrated user's slang-heavy complaint into a "Formal" and "Polite" summary for a manager.
Task
Specify the role of the "System" message to ensure the model acts appropriately, and write the "User" prompt to translate: 'The app is buggy as heck and I want my money back ASAP!'
System Message:
"You are a professional executive assistant. Your task is to rephrase communication into a formal, corporate-appropriate tone."

User Prompt:
"Translate the following text into a formal summary: 'The app is buggy as heck and I want my money back ASAP!'"

Expected Result:
"The customer is reporting technical instability within the application and is requesting an immediate refund."